Skip to content

fix(desktop): sign the release DMG before notarizing it - #1615

Merged
Gajesh2007 merged 1 commit into
masterfrom
fix/desktop-release-sign-dmg
Oct 26, 2026
Merged

Gajesh2007 merged 1 commit into
masterfrom
fix/desktop-release-sign-dmg

Conversation

@jonathan308

@jonathan308 jonathan308 commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

The first dry run of Release Desktop App (run 40395709311) built, signed, notarized and stapled the app (spctl: Notarized Developer ID), and notarized and stapled the DMG. It then failed the final check: Gatekeeper rejected the DMG because electron-builder leaves the DMG itself unsigned.

Darkbloom-0.1.0-arm64.dmg: rejected
source=no usable signature

This signs the DMG with the same Eigen Labs Developer ID before notarizing it. It also makes the verify step check that signature, so a release can't publish a DMG that Gatekeeper rejects. This blocks tagging desktop-v0.1.0.

Before / After

flowchart LR
  subgraph Before["Before"]
    direction TB
    B1["App: signed, notarized, stapled ✓"]:::code --> B2["DMG: unsigned → notarized, stapled"]:::bad
    B2 --> B3(["spctl: rejected<br/>no usable signature"]):::bad
  end
  subgraph After["After"]
    direction TB
    A1["App: signed, notarized, stapled ✓"]:::code --> A2["DMG: codesign (SLDQ2GJ6TL) → notarized, stapled"]:::fix
    A2 --> A3(["spctl: accepted<br/>Notarized Developer ID"]):::good
  end
  classDef code fill:#312e81,stroke:#a5b4fc,color:#eef2ff
  classDef bad fill:#7f1d1d,stroke:#fca5a5,color:#fef2f2
  classDef fix fill:#065f46,stroke:#6ee7b7,color:#ecfdf5
  classDef good fill:#14532d,stroke:#86efac,color:#f0fdf4
Loading

Legend: indigo = unchanged, red = defect, green = changed step / fixed outcome.

Changes

  • .github/workflows/release-desktop.yml
    • Sign, notarize and staple the DMG: runs codesign --sign "$CSC_NAME" --keychain "$KEYCHAIN_PATH" --timestamp on the DMG before notarytool submit. It uses the same fingerprint-selected Developer ID and temporary keychain as the app.
    • Verify the release:
      • checks the DMG with codesign --verify;
      • requires the DMG's team to be SLDQ2GJ6TL;
      • requires spctl --assess --type open to report source=Notarized Developer ID. Before this, a rejection only failed through the exit code.
  • docs/operations/desktop-release.md: the verification list covers the DMG signature.
  • changelog.d/desktop-release-sign-dmg.md.

Validation

  • Reproduced locally with a throwaway DMG:
    • unsigned: rejected, source=no usable signature, the same as CI;
    • signed but not notarized: rejected, source=Unnotarized Developer ID, so only notarization was missing, and CI does that;
    • codesign -dv reports the team ID from a signed DMG, which the new team check relies on.
  • ruby -ryaml -e 'YAML.load_file(".github/workflows/release-desktop.yml")', python3 scripts/changelog.py check and make docs-impact-check BASE=origin/master all pass.
  • Dry run from this branch, run 40396640521: passed. Every verify check is green:
    mac-arm64/Darkbloom.app: accepted
    source=Notarized Developer ID
    Darkbloom-0.1.0-arm64.dmg: accepted
    source=Notarized Developer ID
    
  • Re-checked the downloaded artifact locally:
    • shasum -a 256 -c SHA256SUMS OK;
    • the DMG codesign --verify passes, with TeamIdentifier=SLDQ2GJ6TL;
    • spctl reports Notarized Developer ID;
    • stapler validate passes.

No app code changes. No new secrets.

Components touched

  • CI / provider release (desktop release workflow)
  • docs

Protocol / interface changes

  • No protocol/interface changes

🤖 Generated with Claude Code

The first desktop release dry run (run 40395709311) built, signed,
notarized and stapled the app, and notarized and stapled the DMG, but
Gatekeeper rejected the DMG: `spctl --assess --type open` reported
`source=no usable signature`. electron-builder leaves the DMG unsigned.

Sign the DMG with the same Developer ID (by fingerprint, from the
temporary keychain) before submitting it to notarization, and verify
the DMG's signature, team and `Notarized Developer ID` assessment.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Oct 26, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
d-inference Ready Ready Preview Oct 26, 2026 8:37pm UTC
d-inference-console-ui-dev Ready Ready Preview Oct 26, 2026 8:37pm UTC
d-inference-landing Ready Ready Preview Oct 26, 2026 8:37pm UTC
darkbloom-status Ready Ready Preview Oct 26, 2026 8:37pm UTC
eigen-homepages-darkbloom Ready Ready Preview Oct 26, 2026 8:37pm UTC

Request Review

@github-actions

github-actions Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Threat model review — advisory

Reviewed head 0bce42b3aae1 against base f9d1af3d0d3e.

Reviewers: anthropic/claude-sonnet-5.5: first pass completed; anthropic/claude-opus-5.5: not needed by escalation policy; openai/gpt-6.1-sol: selected depth completed (1 batches)

No actionable findings in the reviewed text. This is not a security approval.

Models: budgeted Sonnet / selective Opus / selective Sol 6.1. Findings require human validation; this review never requests changes or blocks merging.

Scan completed.

Coverage: 11/11 source units; cross-file integration complete. 0 selected depth batch(es) pending. All threat definitions indexed; relevant full definitions selected. Unchanged callers are not scanned.

Cost this run: $0.0000 reported, $0.0000 reserved with unknown cost; 0 paid request(s), 0 reused batch(es), 0 provider cache-hit tokens.

Saved findings and earlier report · Historical findings are not confirmed resolved.

Bedrock: 4 request(s), 65773 uncached + 0 cache-read + 39132 cache-write input / 2599 output tokens; 0 request(s) with unknown usage. OpenRouter backup used 0 time(s). Dollar amounts above cover OpenRouter only; AWS billing is reconciled separately.
Workload allowance: 5 native request(s), including one shared response repair; 500 emergency ceiling. Selected depth and integration rounds are admitted as their scope becomes known.

@Gajesh2007
Gajesh2007 merged commit ad7dd81 into master Oct 26, 2026
27 checks passed
jonathan308 added a commit that referenced this pull request Oct 27, 2026
Brings in #1615, #1618 (provider 0.10.3 hotfix), #1617, #1619 and #1620
(reversible add-on hold).

Conflicts and resolutions:
- docs/provider/cli-reference.md: only the "Last updated" stamp
  conflicted (2026-10-26 here, 2026-10-27 on master). Kept the one
  2026-10-27 stamp; both texts are kept (this branch's served-count lines
  and master's `darkbloom addon` section merged cleanly).

No semantic interplay with #1620: the served counts and the add-on hold's
"Not serving: held by add-on" status line are independent.
jonathan308 added a commit that referenced this pull request Oct 27, 2026
Brings in #1615, #1618 (provider 0.10.3 hotfix), #1617, #1619 and #1620
(reversible add-on hold).

Conflicts and resolutions:
- docs/provider/cli-reference.md: only the "Last updated" stamp
  conflicted (2026-10-26 here, 2026-10-27 on master). Kept the one
  2026-10-27 stamp; both texts are kept.
- docs/reference/protocol-messages.md: only the "Last updated" stamp
  conflicted. Kept the one 2026-10-27 stamp; this branch's no-session
  drain text and master's busy_reason/busy_since_ms/busy_addon fields
  merged cleanly.

provider-swift/Sources/ProviderCore/ProviderLoop+Lifecycle.swift merged
cleanly: #1620 changes beginServingDrain and the lifecycle monitor, this
branch only the end of performLifecycleDrain (coordinatorSettled).

Interplay with #1620, reviewed: an add-on hold keeps its registered
connection, so the stop path still waits for the coordinator's drain
acknowledgement while held; only a stop without a registered session
skips it. A planned reconnect under a hold goes through the bounded
handshake, and its fresh register still carries the busy fields.
jonathan308 added a commit that referenced this pull request Oct 27, 2026
Brings in #1615, #1618 (provider 0.10.3 hotfix), #1617, #1619 and #1620
(reversible add-on hold).

Conflicts and resolutions:
- provider-swift/Sources/ProviderCore/Service/DaemonState+Coding.swift:
  both sides appended a daemon-state key to the same CodingKeys line
  (`coordinatorConnection` here, `addonHold` from #1620). Kept both as
  `case autopilotState, coordinatorConnection, addonHold`, matching the
  struct's field order and the encode order. The decode/encode bodies
  merged cleanly; both keys stay optional (decodeIfPresent and
  encodeIfPresent), so files from older daemons still decode and older
  readers ignore the new keys.
- docs/provider/cli-reference.md: only the "Last updated" stamp
  conflicted (2026-10-26 here, 2026-10-27 on master). Kept the one
  2026-10-27 stamp; both texts are kept (this branch's Traffic line and
  master's `darkbloom addon` section).

DaemonStateFile.swift and ProviderLoop+Trust.swift merged cleanly: the
DaemonState initializer takes coordinatorConnection before appAttest and
addonHold last, and writeDaemonState passes both in that order.
jonathan308 added a commit that referenced this pull request Oct 27, 2026
Brings in #1615, #1618 (provider 0.10.3 hotfix), #1617, #1619 and #1620
(reversible add-on hold).

Conflicts and resolutions:
- docs/architecture/model-autopilot.md: only the "Last updated" stamp
  conflicted (2026-10-26 here, 2026-10-27 on master). Kept the one
  2026-10-27 stamp; both texts are kept (this branch's selected-model
  recovery sections and master's `addon_hold` busy reason).
- docs/provider/cli-reference.md: only the "Last updated" stamp
  conflicted. Kept the one 2026-10-27 stamp; both texts are kept.

Code merged cleanly, including ProviderLoop+AutopilotBusy.swift (the
recovery attempt counts as `preload`; #1620 adds `addon_hold`),
DaemonState+Coding.swift (selectedModelRecovery and addonHold keys) and
ProviderLoop+ModelLoading.swift (an unload makes waiting recoveries due;
an add-on hold's unload keeps the persisted serving set).

Interplay with #1620, reviewed: a recovery check pauses while the hold
owns admission (servingDrain.refusing), and the hold's unload pass waits
for a running attempt (modelSwitchMutationsSettled). The hold did not
cancel an attempt already loading; the next commit fixes that.
davidtai added a commit that referenced this pull request Oct 27, 2026
The merge adds #1615, #1617, #1618 (provider 0.10.3 hotfix), #1619 and
#1620 (reversible add-on hold) to this branch.

Conflicts and resolutions:
- docs/provider/cli-reference.md: only the "Last updated" stamp had a
  conflict (2026-10-26 on this branch, 2026-10-27 on master). The merge
  keeps one stamp, 2026-10-27. It keeps the two texts: the reconnect
  rows of this branch in the runtime constants, and the `darkbloom addon`
  section and the add-on runtime row of master.
- docs/reference/protocol-messages.md: only the "Last updated" stamp had
  a conflict. The merge keeps one stamp, 2026-10-27. Git put the
  "Add-on hold busy fields" section of master and the "Close codes and
  the reconnect wait" section of this branch one after the other, after
  "Provider lifecycle drain". The file has each section one time.

Git merged all code without a conflict. Only CoordinatorClientState.swift
changed on the two sides. Master adds the ProviderState.busy property.
This branch adds the CoordinatorSessionRecorder class. These changes are
in different types. The new code of master does not call the symbols
that this branch changes: ExponentialBackoff.nextDelay(), the private
functions in CoordinatorClient+Connection.swift and
MockCoordinator.dropActiveWebSocket. The gitlinks are those of master:
libs/mlx 31f550af, libs/mlx-swift 4926d3d9, libs/mlx-swift-lm aee6ebb6.
Against master, the branch has the same changes as before, except the
two stamps.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
jonathan308 added a commit that referenced this pull request Oct 27, 2026
Brings in #1615, #1617, #1618 (provider 0.10.3 hotfix), #1619, #1620 and
#1623 (add-on hold), #1621 (Qwen JSON response formats without default
thinking) and #1622 (Qwen JSON response_format answers under the JSON
grammar).

Conflicts and resolutions:
- docs/architecture/inference.md: only the "Last updated" stamp
  conflicted (2026-10-26 here, 2026-10-27 on master). Kept the one
  2026-10-27 stamp; both texts are kept (this branch's forced-admission
  table and whitespace rule, and master's constrained Qwen JSON answer
  sections, merged cleanly).

Interplay with #1621 and #1622 (same Qwen 3.5/3.6 families):
- QwenJSONAnswerPolicy installs the JSON grammar only for requests with
  no tools and no tool_choice, so a forced request keeps this branch's
  prompt-forced, withheld and post-validated path with no token
  constraint, also when it carries a JSON response_format.
- templateAdditionalContext turns thinking off for forced legacy Qwen
  before #1621's JSON default is consulted; both give
  enable_thinking=false, and caller controls stay overridden on the
  forced path as before.
- NativeToolStreamRouter drops framing whitespace only when a tool call
  is required. A constrained JSON answer is never forced, so its bytes,
  including whitespace, stream unchanged.
@Gajesh2007 Gajesh2007 mentioned this pull request Oct 27, 2026
7 of 9 tasks

This branch was successfully deployed

5 active deployments
Preview – d-inference — 0bce42b3 Deployed Oct 26, 2026 by vercel[bot]
Preview – d-inference-console-ui-dev — 0bce42b3 Deployed Oct 26, 2026 by vercel[bot]
Preview – eigen-homepages-darkbloom — 0bce42b3 Deployed Oct 26, 2026 by vercel[bot]
Preview – d-inference-landing — 0bce42b3 Deployed Oct 26, 2026 by vercel[bot]
Preview – darkbloom-status — 0bce42b3 Deployed Oct 26, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants